package com.aaa.service.impl;

import com.aaa.commen.domain.AssetCompany;
import com.aaa.commen.entity.Result;
import com.aaa.mapper.AssetCompanyMapper;
import com.aaa.service.IAssetCompanyService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author ${author}
 * @since 2021-02-23
 */
@Service
public class AssetCompanyServiceImpl extends ServiceImpl<AssetCompanyMapper, AssetCompany> implements IAssetCompanyService {

    @Autowired
    private AssetCompanyMapper assetCompanyMapper;

    /**
     * 查询公司信息(用作下拉框)
     * @return
     */
    @Override
    public Result queryCompanyInfo() {
        List<AssetCompany> assetCompanies = assetCompanyMapper.selectList(null);
        return Result.success(assetCompanies);
    }
}
